package com.changgou.service.goods.service;

import com.changgou.goods.pojo.Brand;
import com.github.pagehelper.Page;

import java.util.List;
import java.util.Map;

/**
 * @Author: JoinCao
 * @CreateDate: 2020-03-13
 */
public interface BrandService {
    /**
     * @Author: JoinCao
     * @CreateDate: 2020-03-13
     * @Description: 品牌列表查询
     */
    List<Brand> findList();

    /**
     * @Author: JoinCao
     * @CreateDate: 2020-03-13
     * @Description: 根据id查询品牌数据
     */
    Brand findById(Integer id);

    /**
     * @Author: JoinCao
     * @CreateDate: 2020-03-13
     * @Description: 品牌新增
     */
    void add(Brand brand);

    /**
     * @Author: JoinCao
     * @CreateDate: 2020-03-13
     * @Description: 根据id删除品牌信息
     */
    void delById(Integer id);

    /**
     * @Author: JoinCao
     * @CreateDate: 2020-03-13
     * @Description: 品牌修改
     */
    void update(Brand brand);

    /**
     * @Author: JoinCao
     * @CreateDate: 2020-03-13
     * @Description: 品牌列表条件查询
     */
    List<Brand> list(Map<String, Object> searchMap);

    /**
     * @Author: JoinCao
     * @CreateDate: 2020-03-13
     * @Description: 品牌列表分页查询
     */
    /*
    page当前页码
    size每页显示条数
    */
    Page<Brand> findPage(int page, int size);

    /**
     * @Author: JoinCao
     * @CreateDate: 2020-03-14
     * @Description: 品牌列表分页+条件查询
     */
    Page<Brand> findPage(Map<String, Object> searchMap, int page, int size);
}
